<template>
	<el-breadcrumb separator="/">
		<el-breadcrumb-item v-for="route in matchedLinks" :to="{ path: route.path }" :replace="true" :key="route.path">{{
			route.meta.title
		}}</el-breadcrumb-item>
	</el-breadcrumb>
</template>

<script>
export default {
	computed: {
		matchedLinks() {
			const navLinks = this.$route.matched.filter(route => route.meta && route.meta.title);
			return navLinks;
		},
	},
};
</script>

<style lang="scss" scoped></style>
